﻿<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.w3.org/1999/xhtml">
<head>

    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="description" content="Neon is a Responsive Bootstrap 4 Admin Dashboard Template">
    <meta name="keywords" content="admin, admin template, admin panel, dashboard template, ui kits, web app, crm, cms, responsive, bootstrap 4, html, sass support, scss">
    <meta name="author" content="Themesbox">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=0, minimal-ui">

    <title>pctz</title>

    <!-- Fevicon -->
    <link rel="shortcut icon" href="assets/images/favicon.ico">

    <!-- Start CSS -->
    <link href="http://cdn.bootstrapmb.com/bootstrap/4.3.1/css/bootstrap.min.css" rel="stylesheet" type="text/css">
    <link href="assets/css/icons.css" rel="stylesheet" type="text/css">
    <link href="assets/css/style.css" rel="stylesheet" type="text/css">
    <!-- End CSS -->
<script>

</script>
</head>

<body class="xp-vertical">

<div class="xp-authenticate-bg"></div>
<!-- Start XP Container -->
<div id="xp-container" class="xp-container">

    <!-- Start Container -->
    <div class="container">

        <!-- Start XP Row -->
        <div class="row vh-100 align-items-center">
            <!-- Start XP Col -->
            <div class="col-lg-12 ">

                <!-- Start XP Auth Box -->
                <div class="xp-auth-box">

                    <div class="card">
                        <div class="card-body">
                           <!-- <h3 class="text-center mt-0 m-b-15">
                                <a href="userInfoPage.do" class="xp-web-logo"><img src="assets/images/logo.svg" height="40" alt="logo"></a>
                            </h3>-->
                            <div class="p-3">
                                <form action="#">
                                    <div class="text-center mb-3">
                                        <h4 class="text-black">登录</h4>
                                    </div>
                                    <div class="login-or">
                                        <h6 class="text-muted">---</h6>
                                    </div>
                                    <div class="form-group">
                                        <input type="text" class="form-control" id="name" placeholder="账号" >
                                    </div>
                                    <div class="form-group">
                                        <input type="password" class="form-control" id="password" placeholder="密码">
                                    </div>
<!--                                    <div class="form-row">-->
<!--                                        <div class="form-group col-6">-->
<!--                                            <div class="custom-control custom-checkbox">-->
<!--                                                <input type="checkbox" class="custom-control-input" id="rememberme"  checked="checked">-->
<!--                                                <label class="custom-control-label" for="rememberme">记住密码</label>-->
<!--                                            </div>-->
<!--                                        </div>-->
<!--                                        <div class="form-group col-6 text-right">-->
<!--                                            <label class="forgot-psw">-->
<!--                                                <a id="forgot-psw" href="forgotpswPage.do">忘记密码?</a>-->
<!--                                            </label>-->
<!--                                        </div>-->
<!--                                    </div>-->
                                    <button type="button" class="btn btn-primary btn-rounded btn-lg btn-block" onclick="login()">登录</button>
                                </form>
                            </div>
                        </div>
                    </div>

                </div>
                <!-- End XP Auth Box -->

            </div>
            <!-- End XP Col -->
        </div>
        <!-- End XP Row -->
    </div>
    <!-- End Container -->
</div>
<!-- End XP Container -->

<!-- Start JS -->
<script src="assets/js/jquery.min.js"></script>
<script src="assets/js/popper.min.js"></script>
<script src="http://cdn.bootstrapmb.com/bootstrap/4.3.1/js/bootstrap.min.js"></script>
<script src="assets/js/modernizr.min.js"></script>
<script src="assets/js/detect.js"></script>
<script src="assets/js/jquery.slimscroll.js"></script>
<script src="assets/js/sidebar-menu.js"></script>

<!-- Main JS -->
<script src="assets/js/main.js"></script>
<!-- End JS -->

</body>
<script>
    function login() {
      let name=$("#name").val();
      let password=$("#password").val();
      $.ajax({
          url:"login.do",
          data:{
            name:name,
              password:password
          },
          type:"get",
          dataType:"text",
          success:function (xxx) {
              if(xxx=="登录成功"){
                  location = "indexPage.do";
              }else {
                  alert("密码或账号错误，重新输入")
              }
          },
          error:function () {
           alert("网络错误")
          }
      })
    }
</script>
    
</html>
